﻿using Unity.Entities;
using UnityEngine;


public class EnemyAuthoring : MonoBehaviour
{

    public class Baker : Baker<EnemyAuthoring>
    {
        public override void Bake(EnemyAuthoring authoring)
        {
            var entity = GetEntity(TransformUsageFlags.Dynamic);
            AddComponent<EnemyTag>(entity);
            AddComponent<InstantiateGameObjectTag>(entity);
            AddComponent<TransAsyncInfo>(entity);
            AddComponent<EnemyData>(entity);
            AddComponent<PoolReceiveTag>(entity);

            SetComponentEnabled<InstantiateGameObjectTag>(entity, true);
            SetComponentEnabled<PoolReceiveTag>(entity, false);
        }
    }
}
